<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <script src="lib/jquery-3.2.1.js"></script>
    <meta name="referrer" content="no-referrer">
</head>
<body>
    <p title="hello world"> hello world</p>
    <img src="" alt="">
    <script>
        $.ajax({
            url:"http://192.168.3.8:4444/detail",
            type:"get",
            success:function(res){
                var tag = res.result.data[0].tag;
                var avatar = res.result.data[0].avatar;
                console.log(avatar)
                // .html() 可以改变元素的内容
                $("p").html(tag)
                $("img").attr("src",avatar)
            }
        })
    </script>
</body>
</html>